import {request} from "../utils/index.js";

export function getSpecialtyInfo(name) {
    return request({
        url: `/getSpecialtyInfo?name=${name}`,
        method : "get"
    })
}

export function addSpecialtyInfo(data) {
    return request({
        url: "/addSpecialtyInfo",
        method : "post",
        data
    })
}

export function deleteSpecialtyInfo(data) {
    return request({
        url: "/deleteSpecialty",
        method : "delete",
        data
    })
}

export function updateSpecialtyInfo(data) {
    return request({
        url: "/updateSpecialty",
        method : "post",
        data
    })
}

export function batchDeleteSpecialtyInfo(data) {
    return request({
        url: "/batchDeleteSpecialty",
        method : "delete",
        data
    })
}

export function getSpecialtyByAcademyId(academyId) {
    return request({
        url: `/getSpecialtyByAcademyId?academyId=${academyId}`,
        method : "get"
    })
}